export default {
    component: 'jzlPageTabs',
    icon: 'fa fa-digital-tachograph',
    name: 'Tabs',

    box_style: null,
    ele_style: {
        _name: 'Tabs',
        _render: '_ele',
        _node: 'div',
        _ss: {},
        _sh: {},
        _rh: false,
        _se: [ "change" ],
        _fix: "all",

        tab: {
            _node: "list",
            _name: 'Tab 列表',
            _ss: {},
            _sh: {},
            _rh: false,
            _value: 'options',

            label: {
                _name: "Tab文本 & 样式",
                _node: "text",
                _value: 'scope:label'
            },
            value: {
                _name: "Tab值 & 选中样式",
                _node: "text",
                _value: 'scope:value'
            }
        }
    },
    setting: {
        sticky: false,
        type: "",
        color: "",
        lineWidth: 40,
        lineHeight: 3
    },
    vars: [{
        prop: "model",
        type: "string",
        default: "",
        force: true,
        initType: "static",
        // initPath: "",
        // varName: "",    // page var name
        // emptyDefault: true,
        // api: null,
        // mbCode: null,
        // formCode: null,
        // viewCode: null,
        // itemName: null,
        // apiFilter: {},
        // mapiFilter: {}
    }, {
        prop: "options",
        type: "json",
        default: null,
        force: true,
        initType: "static",
        // initPath: "",
        // varName: "",    // page var name
        // emptyDefault: true,
        // api: null,
        // mbCode: null,
        // formCode: null,
        // viewCode: null,
        // itemName: null,
        // apiFilter: {},
        // mapiFilter: {}

        defaultJson: [{
            label: "Tab 1",
            value: "A"
        }, {
            label: "Tab 2",
            value: "B"
        }]
    }],
    data_fieldsmap: {},
    data_schema: {       // 组件需要的字段
        "$schema": "http://json-schema.org/draft-04/schema#",
        "title": "数据列表",
        "description": "list description",
        "type": "array",
        "items": {
            "title": "",
            "type": "object",
            "properties": {
                "label": {
                    "title": "名称",
                    "type": "string"
                },
                "value": {
                    "title": "值",
                    "type": "string"
                }
            }
        }
    },
    setting_schema: {
        "$schema": "http://json-schema.org/draft-04/schema#",
        "title": "Tabs 组件参数设置",
        "description": "",
        "type": "object",
        "properties": {
            "type": {
                "title": "样式风格",
                "type": "string",
                "ui:widget": "RadioWidget",
                "enum": [
                    "line",
                    "card"
                ],
                "enumNames": [
                    "线条",
                    "卡片"
                ]
            },
            "color": {
                "title": "主题色",
                "type": "string",
                "ui:widget": "ColorPicker"
            },
            "lineWidth": {
                "title": "线条宽度",
                "type": "integer",
                "minimum": 0,
                "maximum": 200,
                "default": 40,
                'ui:widget': 'el-slider'
            },
            "lineHeight": {
                "title": "线条高度",
                "type": "integer",
                "minimum": 0,
                "maximum": 20,
                "default": 3,
                "ui:widget": "el-slider"
            },

        }
    },
    data_type: 'static',    // static | dync
    data_dync: {},
    data_static: [{ label: "Tab1", value: 1 }, { label: "Tab2", value: 2 }]
}
